// //这里是的配置是home下面的所有子路由的路由配置
// //一个路由配置要满足的条件,必须符合一个routes的格式 一个数组,里面有很多的对象,对象中使用path对应component

// const allRoutes = [
//     {
//         path: "/mine",
//         component: () =>
//             import(/*webpackChunkName:'mine'*/ "../pages/Home/Mine"),
//         // 路由元信息
//         name: "mine",//具名路由
//         meta: {
//             //储存一些用户定义的属性
//             name: "我的中心",
//             icon: "iconfont icon-shouye1",//存菜单对应的图标的类名
//             fullPath: "/home/mine",//当前路由的完整路径
//         }
//     },
//     {
//         path: "/welcome",
//         component: () =>
//             import(/*webpackChunkName:'welcome'*/ "../pages/Home/Welcome"),
//         // 路由元信息
//         name: "welcome",
//         meta: {
//             //储存一些用户定义的属性
//             fullPath: "/home/welcome",
//             name: "管理首页",
//             icon: "iconfont icon-icon-test"
//         },
//     }
// ]

const allRoutes = [
  {
    path: "welcome",
    component: () =>
      import(/*webpackChunkName:"welcome" */ "../pages/Home/Welcome"),
    name: "welcome",
    meta: {
      //储存一些属性
      fullPath: "/welcome",
      icon: "iconfont icon-shouye1",
      name: "管理首页",
    },
  },
  {
    path: "studentManager",
    component: () =>
      import(
        /*webpackChunkName:"studentManager" */ "../pages/Home/StudentManager"
      ),
    name: "studentManager",
    redirect: "/studentManager/product",
    meta: {
      //储存一些属性
      fullPath: "/studentManager",
      icon: "iconfont icon-xueyuan1",
      name: "学员管理",
    },
    children: [
      {
        path: "dormitory",
        component: () =>
          import(
            /*webpackChunkName:"dormitory" */ "../pages/Home/StudentManager/StudentDormitory"
          ),
        name: "dormitory",
        meta: {
          //储存一些属性
          fullPath: "/studentManager/dormitory",
          icon: "iconfont icon-shouye",
          name: "学员宿舍",
        },
      },
      {
        path: "product",
        component: () =>
          import(
            /*webpackChunkName:"product" */ "../pages/Home/StudentManager/StudentProduct"
          ),
        name: "product",
        meta: {
          //储存一些属性
          fullPath: "/studentManager/product",
          icon: "iconfont icon-shangpinguanli",
          name: "学员项目管理",
        },
      },
      {
        path: "profill",
        component: () =>
          import(
            /*webpackChunkName:"profill" */ "../pages/Home/StudentManager/StudentProfill"
          ),
        name: "profill",
        meta: {
          //储存一些属性
          fullPath: "/studentManager/profill",
          icon: "iconfont icon-shuju1",
          name: "学员资料",
        },
      },
    ],
  },
  {
    path: "users",
    component: () =>
      import(/*webpackChunkName:"users" */ "../pages/Home/Users"),
    name: "users",
    meta: {
      //储存一些属性
      fullPath: "/users",
      icon: "iconfont icon-yonghu",
      name: "用户管理",
    },
  },
  {
    path: "attendance",
    component: () =>
      import(/*webpackChunkName:"attendance" */ "../pages/Home/Attendance"),
    name: "attendance",
    meta: {
      //储存一些属性
      fullPath: "/attendance",
      icon: "iconfont icon-kaoqin3",
      name: "考勤管理",
    },
  },
  {
    path: "statistics",
    component: () =>
      import(/*webpackChunkName:"statistics" */ "../pages/Home/Statistics"),
    name: "statistics",
    meta: {
      //储存一些属性
      fullPath: "/statistics",
      icon: "iconfont icon-shuju2",
      name: "数据统计",
    },
  },
  {
    path: "mine",
    component: () => import(/*webpackChunkName:"mine" */ "../pages/Home/Mine"),
    name: "mine",
    meta: {
      //储存一些属性
      fullPath: "/mine",
      icon: "iconfont icon-wode",
      name: "我的中心",
    },
  },
];

export default allRoutes;
